<?php 
$this->extend('/Comun/panel');
$this->assign('clase', 'grid-1');
$this->assign('titulo', 'Departamentos');
 ?>
          
          
          <?php echo $this->Html->link('Agregar Departamento', array('controller' => 'departamentos', 'action' => 'add')); ?>
          
                 <table class="display" id="">
                 
       
          <thead>
              <tr>
                  <th><?php echo $this->Paginator->sort('Id', 'id'); ?></th> 
                  <th><?php echo $this->Paginator->sort('Nombre', 'nombre'); ?></th> 
                  <th><?php echo $this->Paginator->sort('Departamento', 'descripcion'); ?></th> 
                  <th>&nbsp;</th> 
              </tr>
              
              </thead>
              
              <tbody>
              <?php foreach ($departamentos as $departamento): ?>
                  <tr class="item">
                      <td><?php echo $departamento['Departamento']['id']; ?></td>
                      <td><?php echo $departamento['Departamento']['nombre']; ?></td>
                      <td><?php echo $departamento['Departamento']['descripcion']; ?></td>
                      <td>
                          <?php echo $this->Html->link('Editar', array('action' => 'edit', $departamento['Departamento']['id'])); ?>
          
                          <?php
                          
                          echo $this->Form->postLink('Eliminar', array('action' => 'delete', $departamento['Departamento']['id']), array('confirm' => '¿En verdad desea eliminar este elemento?'));

                          ?>
                          
                       
                          
                      </td>
                  </tr>
              <?php endforeach; ?>
              
              
              </tbody>
              
          </table>
          <?php echo $this->Paginator->numbers(); ?>
          <?php echo $this->Paginator->prev('« Anterior ', null, null, array('class' => 'disabled')); ?>
          <?php echo $this->Paginator->next(' Siguiente »', null, null, array('class' => 'disabled')); ?> 
          
          
 









          



